package com.guoning.office_system.mapper;

import com.guoning.office_system.model.AccountingRecord;
import com.guoning.office_system.model.AccountingRecordWithUserAndRoom;
import com.guoning.office_system.vo.Criteria;
import org.apache.ibatis.annotations.Mapper;
import org.springframework.stereotype.Component;

import java.util.List;

@Mapper
@Component("AccountingRecordMapper")
public interface AccountingRecordMapper {
    Long selectByConditionCount(Criteria criteria);

    List<AccountingRecordWithUserAndRoom> selectByCondition(Criteria criteria);

    List<AccountingRecordWithUserAndRoom> selectByTimeAndRecordId(AccountingRecord accountingRecord);

    int deleteByPrimaryKey(Long id);

    int insert(AccountingRecord record);

    int insertSelective(AccountingRecord record);

    AccountingRecordWithUserAndRoom selectByPrimaryKey(Long id);

    int updateForDelete(List<AccountingRecord> recordList);

    int updateRecordStatus(List<AccountingRecord> recordList);

    int updateByPrimaryKeySelective(AccountingRecord record);

    int updateByPrimaryKey(AccountingRecord record);
}